/**
 * Copyright &copy; 2012-2016 <a href="https://github.com/thinkgem/jeesite">JeeSite</a> All rights reserved.
 */
package com.thinkgem.jeesite.modules.accountinfo.entity;

import org.apache.ibatis.type.Alias;
import org.hibernate.validator.constraints.Length;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;

import com.thinkgem.jeesite.common.persistence.DataEntity;

/**
 * 用户注册Entity
 * @author ljh
 * @version 2016-12-14
 */
@Alias("accountInfo")
public class AccountInfo extends DataEntity<AccountInfo> {
	
	private static final long serialVersionUID = 1L;
	private String username;		// 用户
	private String telNum;		// 绑定手机号
	private String email;		// 邮箱
	private String wechatNum;		// 微信号
	private String qqNum;		// qq号
	private String passWord;		// 密码
	private Date createTime;		// create_time
	private Integer userStatus;		// 用户状态 1正常 0禁用  2注销
	private Integer userPhoneStatus;		// 账号手机0未验证, 1已验证
	private Integer userEmailStatus;		// 账号邮箱0未验证 1已验证
	private Integer userType;		// user_type
	private String phoneValidateCode;		// 手机验证码
	
	//private List<AccountInfoAddress> accountInfoAddress = new ArrayList<AccountInfoAddress>();
	
	public AccountInfo() {
		super();
	}

	public AccountInfo(String id){
		super(id);
	}

	@Length(min=0, max=300, message="用户名长度必须介于 0 和 300 之间")
	public String getUsername() {
		return username;
	}

	public void setUsername(String username) {
		this.username = username;
	}
	
	@Length(min=0, max=11, message="绑定手机号长度必须介于 0 和 11 之间")
	public String getTelNum() {
		return telNum;
	}

	public void setTelNum(String telNum) {
		this.telNum = telNum;
	}
	
	@Length(min=0, max=45, message="邮箱长度必须介于 0 和 45 之间")
	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}
	
	@Length(min=0, max=20, message="微信号长度必须介于 0 和 20 之间")
	public String getWechatNum() {
		return wechatNum;
	}

	public void setWechatNum(String wechatNum) {
		this.wechatNum = wechatNum;
	}
	
	@Length(min=0, max=16, message="qq号长度必须介于 0 和 16 之间")
	public String getQqNum() {
		return qqNum;
	}

	public void setQqNum(String qqNum) {
		this.qqNum = qqNum;
	}
	
	@Length(min=0, max=100, message="密码长度必须介于 0 和 20 之间")
	public String getPassWord() {
		return passWord;
	}

	public void setPassWord(String passWord) {
		this.passWord = passWord;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}
	
	public Integer getUserStatus() {
		return userStatus;
	}

	public void setUserStatus(Integer userStatus) {
		this.userStatus = userStatus;
	}
	
	public Integer getUserPhoneStatus() {
		return userPhoneStatus;
	}

	public void setUserPhoneStatus(Integer userPhoneStatus) {
		this.userPhoneStatus = userPhoneStatus;
	}
	
	@Length(min=0, max=11, message="账号邮箱1未验证 2已验证长度必须介于 0 和 11 之间")
	public Integer getUserEmailStatus() {
		return userEmailStatus;
	}

	public void setUserEmailStatus(Integer userEmailStatus) {
		this.userEmailStatus = userEmailStatus;
	}
	
	public Integer getUserType() {
		return userType;
	}

	public void setUserType(Integer userType) {
		this.userType = userType;
	}
	
	@Length(min=0, max=45, message="手机验证码长度必须介于 0 和 45 之间")
	public String getPhoneValidateCode() {
		return phoneValidateCode;
	}

	public void setPhoneValidateCode(String phoneValidateCode) {
		this.phoneValidateCode = phoneValidateCode;
	}
	
}